﻿<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
    xmlns:System="clr-namespace:System;assembly=mscorlib" 
    xmlns:sdk="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Data" 
    xmlns:sdk1="clr-namespace:System.Windows.Controls.Primitives;assembly=System.Windows.Controls.Data" 
    xmlns:Controls="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Data.Input" 
    xmlns:Micro="clr-namespace:Caliburn.Micro;assembly=Caliburn.Micro" 
    xmlns:toolkit="http://schemas.microsoft.com/winfx/2006/xaml/presentation/toolkit">
    
    <!--THEME COLOR-->
    <Color x:Key="ThemeColor">#FF847846</Color>
    <SolidColorBrush x:Key="ThemeColorBrush" Color="{StaticResource ThemeColor}" />

    <!--CHROME COLOR-->
    <Color x:Key="ChromeColor">#FF909088</Color>
    <SolidColorBrush x:Key="ChromeColorBrush" Color="{StaticResource ChromeColor}" />

    <!--CHROME HI COLOR-->
    <Color x:Key="ChromeColorHi">#FFc0c0b8</Color>
    <SolidColorBrush x:Key="ChromeColorHiBrush" Color="{StaticResource ChromeColorHi}" />

    <!--FEATURE HIGHLIGHT COLOR-->
    <Color x:Key="FeatureHighlightColor">#FFF0D000</Color>
    <SolidColorBrush x:Key="FeatureHighlightOutlineColorBrush" Color="{StaticResource FeatureHighlightColor}" />
    <SolidColorBrush x:Key="FeatureHighlightFillColorBrush" Color="Transparent" />
    
    <!--DRAWN TEXT STYLE-->
    <Style x:Key="DrawnText" TargetType="TextBlock">
        <Setter Property="FontFamily"
				Value="Segoe UI" />
    </Style>

    <!--GENERAL PURPOSE TEXT-->
    <Style x:Key="GeneralText" TargetType="TextBlock">
        <Setter Property="FontFamily"
				Value="Segoe UI" />
        <Setter Property="FontSize"
				Value="12" />
    </Style>

    <!--GENERAL PURPOSE Light TEXT-->
    <Style x:Key="GeneralTextLt" TargetType="TextBlock">
        <Setter Property="FontFamily"
				Value="Segoe UI" />
        <Setter Property="FontSize"
				Value="12" />
        <Setter Property="Opacity"
                Value="0.5" />
    </Style>

    <!--CUSTOMER TITLE-->
    <Style x:Key="CustomerTitle" TargetType="TextBlock">
        <Setter Property="FontFamily"
				Value="Segoe UI Light" />
        <Setter Property="FontSize"
				Value="20" />
        <Setter Property="Opacity"
                Value="0.4" />
    </Style>
    
    <!--MENU ITEM-->
    <Style x:Key="MainMenuItem" TargetType="TextBlock">
        <Setter Property="FontFamily"
				Value="Segoe UI" />
        <Setter Property="Foreground"
				Value="#C0000000" />
        <Setter Property="FontSize"
				Value="32" />
    </Style>

    <!--PAGE TITLE-->
    <Style x:Key="PageTitle" TargetType="TextBlock">
        <Setter Property="FontSize"
				Value="28" />
        <Setter Property="Opacity"
                Value="0.2" />
    </Style>

    <!--SECTION HEADERS-->
    <Style x:Key="SectionHeaders" TargetType="TextBlock">
        <Setter Property="FontSize"
				Value="22" />
    </Style>

    <!--PANEL OPTIONS-->
    <Style x:Key="PanelOptions" TargetType="TextBlock">
        <Setter Property="FontFamily"
				Value="Segoe UI Light" />
        <Setter Property="FontSize"
				Value="12" />
        <Setter Property="Foreground"
				Value="#80000000" />
    </Style>

    <!--LIST ITEMS-->
    <Style x:Key="ListItems" TargetType="TextBlock">
        <Setter Property="FontFamily"
				Value="Segoe UI Light" />
        <Setter Property="FontSize"
				Value="14" />
        <Setter Property="Foreground"
				Value="#C0000000" />
    </Style>
    
    <!--MAIN SUBCONTENT GRID-->
    <Style x:Key="MainSubcontent" TargetType="Grid">
        <Setter Property="Margin"
				Value="24,12,12,4" />
    </Style>
    
    
    <!--ALL ACCORDIANS-->
    <Style TargetType="toolkit:AccordionItem">
        <Setter Property="FontFamily"
				Value="Segoe UI" />
        <Setter Property="FontSize"
				Value="12" />
    </Style>

    <!--LEGEND ITEMS-->
    <Style x:Key="LegendItems" TargetType="TextBlock">
        <Setter Property="FontFamily"
				Value="Segoe UI Light" />
        <Setter Property="FontSize"
				Value="12" />
        <Setter Property="Foreground"
				Value="#C0000000" />
    </Style>

    <!--MENU ITEMS-->
    <Style x:Key="MenuItems" TargetType="TextBlock">
        <Setter Property="FontFamily"
				Value="Segoe UI" />
        <Setter Property="FontSize"
				Value="12" />
        <Setter Property="Foreground"
				Value="#C0000000" />
    </Style>

    <!--FILTER CAPTIONS-->
    <Style x:Key="LegendCaptions" TargetType="TextBlock">
        <Setter Property="FontFamily"
				Value="Segoe UI" />
        <Setter Property="FontSize"
				Value="10" />
        <Setter Property="FontStyle"
				Value="Italic" />
        <Setter Property="Foreground"
				Value="#A0000000" />
    </Style>

    <!-- callout header (title) -->
    <Style x:Key="CalloutHeaderText" TargetType="TextBlock">
        <Setter Property="FontFamily"
				Value="Segoe UI Light" />
        <Setter Property="Opacity" Value="0.66"/>
        <Setter Property="FontSize" Value="48"/>
        <Setter Property="FontWeight" Value="Bold"/>
        <Setter Property="Foreground" Value="Black"/>
        <Setter Property="Margin" Value="0,0,0,16"/>
    </Style>

    <!-- callout field names -->
    <Style x:Key="CalloutFieldText" TargetType="TextBlock">
        <Setter Property="FontFamily"
				Value="Segoe UI" />
        <Setter Property="FontSize" Value="30"/>
        <Setter Property="Foreground" Value="Black"/>
        <Setter Property="FontWeight" Value="Bold"/>
        <Setter Property="VerticalAlignment" Value="Top"/>
        <Setter Property="TextWrapping" Value="Wrap"/>
    </Style>

    <!-- callout values -->
    <Style x:Key="CalloutValueText" TargetType="TextBlock">
        <Setter Property="FontFamily"
				Value="Segoe UI" />
        <Setter Property="FontSize" Value="30"/>
        <Setter Property="Foreground" Value="Black"/>
        <Setter Property="VerticalAlignment" Value="Top"/>
        <Setter Property="TextWrapping" Value="Wrap"/>
    </Style>

    <!--VIRTUAL ITEMS CONTROL-->
    <Style x:Key="VirtualItemsControl" TargetType="ItemsControl">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ItemsControl">
                    <Border>
                        <ScrollViewer Style="{StaticResource CalloutScrollViewer}" 
                                      VerticalScrollBarVisibility="Auto">
                            <ItemsPresenter/>
                        </ScrollViewer>
                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="ItemsPanel">
            <Setter.Value>
                <ItemsPanelTemplate>
                    <VirtualizingStackPanel />
                </ItemsPanelTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!--button style for round metro buttons-->
    <Style x:Key="MetroArrowButtonStyle" TargetType="Button">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="Button">
                    <Grid>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" To="0.4" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BackgroundEllipse"/>
                                        <DoubleAnimation Duration="0" To="0.4" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BackgroundArrow"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" To="0.66" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BackgroundEllipse"/>
                                        <DoubleAnimation Duration="0" To="0.66" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BackgroundArrow"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" To="0.85" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BackgroundEllipse"/>
                                        <DoubleAnimation Duration="0" To="0.85" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BackgroundArrow"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" To="1" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="DisabledEllipse"/>
                                        <DoubleAnimation Duration="0" To="1" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="DisabledArrow"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>

                        <Ellipse x:Name="BackgroundEllipse" Height="32" Width="32" Fill="Transparent" IsHitTestVisible="true" Stroke="Black" StrokeThickness="1.5" Opacity="0"/>
                        <Path x:Name="BackgroundArrow" Width="15" Height="12" Canvas.Left="18.2008" Canvas.Top="22" Stretch="Fill" IsHitTestVisible="false" Opacity="0"
                              Fill="Black" Data="F1 M 29,22L 34,22L 26,30L 44,30L 44,35L 26,35L 33.5166,42.5166L 27.9789,42.5166L 18.2008,32.7386L 29,22 Z "/>

                        <Ellipse x:Name="DisabledEllipse" Height="32" Width="32" Fill="Transparent" IsHitTestVisible="false" Stroke="#FFe0e0e0" StrokeThickness="1.5"  Opacity="0"/>
                        <Path x:Name="DisabledArrow" Width="15" Height="12" Canvas.Left="18.2008" Canvas.Top="22" Stretch="Fill" IsHitTestVisible="false" Opacity="0"
                              Fill="#FFe8e8e8" Data="F1 M 29,22L 34,22L 26,30L 44,30L 44,35L 26,35L 33.5166,42.5166L 27.9789,42.5166L 18.2008,32.7386L 29,22 Z "/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!--Callout ScrollViewers-->
    <Style x:Key="CalloutScrollViewer" TargetType="ScrollViewer">
        <Setter Property="HorizontalContentAlignment" Value="Left"/>
        <Setter Property="VerticalContentAlignment" Value="Top"/>
        <Setter Property="VerticalScrollBarVisibility" Value="Auto"/>
        <Setter Property="HorizontalScrollBarVisibility" Value="Hidden"/>
        <Setter Property="Padding" Value="4"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ScrollViewer">
                    <Grid>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="*"/>
                            <ColumnDefinition Width="18"/>
                        </Grid.ColumnDefinitions>
                        <ScrollBar x:Name="VerticalScrollBar"  ViewportSize="{TemplateBinding ViewportHeight}" Margin="0,32,0,0"
                                   Maximum="{TemplateBinding ScrollableHeight}" Minimum="0" Value="{TemplateBinding VerticalOffset}" 
                                   Grid.Column="1" />
                        <ScrollContentPresenter Cursor="{TemplateBinding Cursor}" x:Name="ScrollContentPresenter" 
                                   ContentTemplate="{TemplateBinding ContentTemplate}" Margin="3"/>
                        
                        <!--<ScrollBar Height="18" Margin="-1,0,18,-16" x:Name="HorizontalScrollBar" 
                                   Visibility="{TemplateBinding ComputedHorizontalScrollBarVisibility}" IsTabStop="False" 
                                   Orientation="Horizontal" ViewportSize="{TemplateBinding ViewportWidth}" 
                                   Maximum="{TemplateBinding ScrollableWidth}" Minimum="0" 
                                   Value="{TemplateBinding HorizontalOffset}" VerticalAlignment="Bottom" 
                                   Grid.ColumnSpan="2"/>-->
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- CUSTOMIZED ScrollBar -->
    <Style x:Key="CalloutScrollBar" TargetType="ScrollBar">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ScrollBar">
                    <Grid x:Name="Root">
                        <Grid.Resources>
                            <ControlTemplate x:Key="RepeatButtonTemplate" TargetType="RepeatButton">
                                <Grid x:Name="Root" Background="Transparent">
                                    <VisualStateManager.VisualStateGroups>
                                        <VisualStateGroup x:Name="CommonStates">
                                            <VisualState x:Name="Normal"/>
                                        </VisualStateGroup>
                                    </VisualStateManager.VisualStateGroups>
                                </Grid>
                            </ControlTemplate>
                       
                            <ControlTemplate x:Key="VerticalIncrementTemplate" TargetType="RepeatButton">
                                <Grid x:Name="Root">
                                    <VisualStateManager.VisualStateGroups>
                                        <VisualStateGroup x:Name="CommonStates">
                                            <VisualState x:Name="Normal"/>
                                            <VisualState x:Name="MouseOver">
                                            </VisualState>
                                            <VisualState x:Name="Pressed">
                                            </VisualState>
                                            <VisualState x:Name="Disabled">
                                            </VisualState>
                                        </VisualStateGroup>
                                    </VisualStateManager.VisualStateGroups>
                                    <Rectangle Fill="#00000000"/>
                                    <Path Height="4" Width="8" Stretch="Uniform" Data="F1 M 531.107,321.943L 541.537,321.943L 536.322,328.042L 531.107,321.943 Z " Fill="#FFFFFFFF"/>
                                </Grid>
                            </ControlTemplate>
                            
                            <ControlTemplate x:Key="VerticalDecrementTemplate" TargetType="RepeatButton">
                                <Grid x:Name="Root">
                                    <VisualStateManager.VisualStateGroups>
                                        <VisualStateGroup x:Name="CommonStates">
                                            <VisualStateGroup.Transitions>
                                                <VisualTransition GeneratedDuration="00:00:00.1000000"/>
                                            </VisualStateGroup.Transitions>
                                            <VisualState x:Name="Normal"/>
                                            <VisualState x:Name="MouseOver">
                                                <Storyboard>
                                                    <ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="path" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)">
                                                        <SplineColorKeyFrame KeyTime="00:00:00" Value="#FFFFC800"/>
                                                    </ColorAnimationUsingKeyFrames>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="path" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1.3"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="path" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1.3"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </VisualState>
                                            <VisualState x:Name="Pressed">
                                                <Storyboard>
                                                    <ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="path" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)">
                                                        <SplineColorKeyFrame KeyTime="00:00:00" Value="#FFFFFFFF"/>
                                                    </ColorAnimationUsingKeyFrames>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="path" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1.3"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="path" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1.3"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="path" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="-2"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </VisualState>
                                            <VisualState x:Name="Disabled">
                                                <Storyboard>
                                                    <ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="path" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)">
                                                        <SplineColorKeyFrame KeyTime="00:00:00" Value="#26FFFFFF"/>
                                                    </ColorAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </VisualState>
                                        </VisualStateGroup>
                                    </VisualStateManager.VisualStateGroups>
                                    <Rectangle Fill="#00000000"/>
                                    <Path Height="4" Width="8" Stretch="Uniform" Data="F1 M 541.537,173.589L 531.107,173.589L 536.322,167.49L 541.537,173.589 Z " Fill="#FF9DBAD4" x:Name="path" RenderTransformOrigin="0.5,1">
                                        <Path.RenderTransform>
                                            <TransformGroup>
                                                <ScaleTransform/>
                                                <SkewTransform/>
                                                <RotateTransform/>
                                                <TranslateTransform/>
                                            </TransformGroup>
                                        </Path.RenderTransform>
                                    </Path>
                                </Grid>
                            </ControlTemplate>
                            <ControlTemplate x:Key="VerticalThumbTemplate" TargetType="Thumb">
                                <Grid>
                                    <VisualStateManager.VisualStateGroups>
                                        <VisualStateGroup x:Name="CommonStates">
                                            <VisualState x:Name="Normal"/>
                                            <VisualState x:Name="MouseOver">
                                            </VisualState>
                                            <VisualState x:Name="Pressed">
                                            </VisualState>
                                            <VisualState x:Name="Disabled">
                                            </VisualState>
                                        </VisualStateGroup>
                                    </VisualStateManager.VisualStateGroups>
                                    <Border Margin="4,0,4,0" CornerRadius="4,4,4,4" BorderThickness="0,1,0,1">
                                        <Border.BorderBrush>
                                            <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                <GradientStop Color="{StaticResource ChromeColorHi}"/>
                                                <GradientStop Color="{StaticResource ChromeColor}" Offset="0.996"/>
                                            </LinearGradientBrush>
                                        </Border.BorderBrush>
                                        <Border.Background>
                                            <LinearGradientBrush EndPoint="1,.5" StartPoint="0,.5">
                                                <GradientStop Color="{StaticResource ChromeColor}"/>
                                                <GradientStop Color="{StaticResource ChromeColorHi}" Offset="1"/>
                                            </LinearGradientBrush>
                                        </Border.Background>
                                    </Border>
                                </Grid>
                            </ControlTemplate>
                            
                        </Grid.Resources>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal"/>
                                <VisualState x:Name="MouseOver"/>
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetName="Root" Storyboard.TargetProperty="Opacity">
                                            <SplineDoubleKeyFrame KeyTime="0" Value="0.5"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="VerticalSmallDecrease" Storyboard.TargetProperty="(UIElement.Opacity)">
                                            <SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.25"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="VerticalSmallIncrease" Storyboard.TargetProperty="(UIElement.Opacity)">
                                            <SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.25"/>
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        
                        <Grid x:Name="VerticalRoot">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition Height="*"/>
                                <RowDefinition Height="Auto"/>
                            </Grid.RowDefinitions>
                            <RepeatButton Height="16" Margin="1" x:Name="VerticalSmallDecrease" IsTabStop="False" Template="{StaticResource VerticalDecrementTemplate}" Grid.Row="0" Interval="50" Background="#FFB2E4FF"/>
                            <RepeatButton Height="0" x:Name="VerticalLargeDecrease" IsTabStop="False" Template="{StaticResource RepeatButtonTemplate}" Grid.Row="1" Interval="50"/>
                            <Thumb Height="18" MinHeight="18" x:Name="VerticalThumb" Template="{StaticResource VerticalThumbTemplate}" Grid.Row="2"/>
                            <RepeatButton x:Name="VerticalLargeIncrease" IsTabStop="False" Template="{StaticResource RepeatButtonTemplate}" Grid.Row="3" Interval="50"/>
                            <RepeatButton Height="16" Margin="1" x:Name="VerticalSmallIncrease" IsTabStop="False" Template="{StaticResource VerticalDecrementTemplate}" Grid.Row="4" Interval="50" RenderTransformOrigin="0.5,0.5">
                                <RepeatButton.RenderTransform>
                                    <TransformGroup>
                                        <ScaleTransform ScaleY="-1"/>
                                        <SkewTransform/>
                                        <RotateTransform/>
                                        <TranslateTransform/>
                                    </TransformGroup>
                                </RepeatButton.RenderTransform>
                            </RepeatButton>
                        </Grid>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="MinWidth" Value="15"/>
    </Style>

    
    <!--MASHUP PANEL SIZE-->
    <System:Double x:Key="MashupPanelSize">300</System:Double>
    
   
    <!--WATERMARK TEXTBOX-->
    <ControlTemplate x:Key="ValidationToolTipTemplate">
        <Grid x:Name="Root" Margin="5,0" Opacity="0" RenderTransformOrigin="0,0">
            <Grid.RenderTransform>
                <TranslateTransform x:Name="xform" X="-25"/>
            </Grid.RenderTransform>
            <VisualStateManager.VisualStateGroups>
                <VisualStateGroup x:Name="OpenStates">
                    <VisualStateGroup.Transitions>
                        <VisualTransition GeneratedDuration="0"/>
                        <VisualTransition GeneratedDuration="0:0:0.2" To="Open">
                            <Storyboard>
                                <DoubleAnimation Duration="0:0:0.2" To="0" Storyboard.TargetProperty="X" Storyboard.TargetName="xform">
                                    <DoubleAnimation.EasingFunction>
                                        <BackEase Amplitude=".3" EasingMode="EaseOut"/>
                                    </DoubleAnimation.EasingFunction>
                                </DoubleAnimation>
                                <DoubleAnimation Duration="0:0:0.2" To="1" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="Root"/>
                            </Storyboard>
                        </VisualTransition>
                    </VisualStateGroup.Transitions>
                    <VisualState x:Name="Closed">
                        <Storyboard>
                            <DoubleAnimation Duration="0" To="0" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="Root"/>
                        </Storyboard>
                    </VisualState>
                    <VisualState x:Name="Open">
                        <Storyboard>
                            <DoubleAnimation Duration="0" To="0" Storyboard.TargetProperty="X" Storyboard.TargetName="xform"/>
                            <DoubleAnimation Duration="0" To="1" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="Root"/>
                        </Storyboard>
                    </VisualState>
                </VisualStateGroup>
            </VisualStateManager.VisualStateGroups>
            <Border Background="#052A2E31" CornerRadius="5" Margin="4,4,-4,-4"/>
            <Border Background="#152A2E31" CornerRadius="4" Margin="3,3,-3,-3"/>
            <Border Background="#252A2E31" CornerRadius="3" Margin="2,2,-2,-2"/>
            <Border Background="#352A2E31" CornerRadius="2" Margin="1,1,-1,-1"/>
            <Border Background="#FFDC000C" CornerRadius="2"/>
            <Border CornerRadius="2">
                <TextBlock Foreground="White" MaxWidth="250" Margin="8,4,8,4" 
                           TextWrapping="Wrap" Text="{Binding (Validation.Errors)[0].ErrorContent}" 
                           UseLayoutRounding="false"/>
            </Border>
        </Grid>
    </ControlTemplate>

    <Style x:Key="WatermarkTextBoxStyle" TargetType="TextBox">
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="Background" Value="#FFFFFFFF"/>
        <Setter Property="Foreground" Value="#FF000000"/>
        <Setter Property="FontFamily" Value="Segoe UI" />
        <Setter Property="FontSize" Value="14" />
        <Setter Property="Padding" Value="2"/>
        <Setter Property="BorderBrush">
            <Setter.Value>
                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                    <GradientStop Color="#FFA3AEB9" Offset="0"/>
                    <GradientStop Color="#FF8399A9" Offset="0.375"/>
                    <GradientStop Color="#FF718597" Offset="0.375"/>
                    <GradientStop Color="#FF617584" Offset="1"/>
                </LinearGradientBrush>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="TextBox">
                    <Grid x:Name="RootElement">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal"/>
                                <VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <ColorAnimation Duration="0" To="#FF99C1E2" Storyboard.TargetProperty="(Border.BorderBrush).(SolidColorBrush.Color)" Storyboard.TargetName="MouseOverBorder"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" To="1" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="DisabledVisualElement"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="ReadOnly">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" To="1" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="ReadOnlyVisualElement"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="FocusStates">
                                <VisualState x:Name="Focused">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" To="1" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="FocusVisualElement"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Unfocused">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" To="0" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="FocusVisualElement"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ValidationStates">
                                <VisualState x:Name="Valid"/>
                                <VisualState x:Name="InvalidUnfocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="ValidationErrorElement">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="InvalidFocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="ValidationErrorElement">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="IsOpen" Storyboard.TargetName="validationTooltip">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <System:Boolean>True</System:Boolean>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Border x:Name="Border" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" CornerRadius="1" Opacity="1">
                            <Grid>
                                <Border x:Name="ReadOnlyVisualElement" Background="#5EC9C9C9" Opacity="0"/>
                                <Border x:Name="MouseOverBorder" BorderBrush="Transparent" BorderThickness="1">
                                    <Grid>
                                        <ScrollViewer x:Name="ContentElement"  BorderThickness="0" IsTabStop="False" Padding="{TemplateBinding Padding}"/>
                                        <TextBlock x:Name="_Watermark" IsHitTestVisible="False" Text="" Foreground="#60000000"
												Padding="{TemplateBinding Padding}" TextWrapping="{TemplateBinding TextWrapping}"/>
                                    </Grid>
                                </Border>
                            </Grid>
                        </Border>
                        <Border x:Name="DisabledVisualElement" BorderBrush="#A5F7F7F7" BorderThickness="{TemplateBinding BorderThickness}" Background="#A5F7F7F7" IsHitTestVisible="False" Opacity="0"/>
                        <Border x:Name="FocusVisualElement" BorderBrush="#FF6DBDD1" BorderThickness="{TemplateBinding BorderThickness}" IsHitTestVisible="False" Margin="1" Opacity="0"/>
                        <Border x:Name="ValidationErrorElement" BorderBrush="#FFDB000C" BorderThickness="1" CornerRadius="1" Visibility="Collapsed">
                            <ToolTipService.ToolTip>
                                <ToolTip x:Name="validationTooltip" DataContext="{Binding RelativeSource={RelativeSource TemplatedParent}}" Placement="Right" PlacementTarget="{Binding RelativeSource={RelativeSource TemplatedParent}}" Template="{StaticResource ValidationToolTipTemplate}">
                                    <ToolTip.Triggers>
                                        <EventTrigger RoutedEvent="Canvas.Loaded">
                                            <BeginStoryboard>
                                                <Storyboard>
                                                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="IsHitTestVisible" Storyboard.TargetName="validationTooltip">
                                                        <DiscreteObjectKeyFrame KeyTime="0">
                                                            <DiscreteObjectKeyFrame.Value>
                                                                <System:Boolean>true</System:Boolean>
                                                            </DiscreteObjectKeyFrame.Value>
                                                        </DiscreteObjectKeyFrame>
                                                    </ObjectAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </BeginStoryboard>
                                        </EventTrigger>
                                    </ToolTip.Triggers>
                                </ToolTip>
                            </ToolTipService.ToolTip>
                            <Grid Background="Transparent" HorizontalAlignment="Right" Height="12" Margin="1,-4,-4,0" VerticalAlignment="Top" Width="12">
                                <Path Data="M 1,0 L6,0 A 2,2 90 0 1 8,2 L8,7 z" Fill="#FFDC000C" Margin="1,3,0,0"/>
                                <Path Data="M 0,0 L2,0 L 8,6 L8,8" Fill="#ffffff" Margin="1,3,0,0"/>
                            </Grid>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!--RADIOBUTTON FOR LISTBOXES-->
    <Style x:Key="CatalogListRadioButton" TargetType="RadioButton">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="RadioButton">
                    <Grid>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="12"/>
                            <ColumnDefinition Width="*"/>
                        </Grid.ColumnDefinitions>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal"/>
                                <VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <ColorAnimation Storyboard.TargetName="contentHighlight" Storyboard.TargetProperty="(Rectangle.Fill).(SolidColorBrush.Color)" Duration="0:0:0.25" To="#10000000"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Storyboard.TargetName="contentPresenter" Storyboard.TargetProperty="(UIElement.Opacity)" Duration="0:0:0.25" To=".55"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="CheckStates">
                                <VisualState x:Name="Checked">
                                    <Storyboard>
                                        <DoubleAnimation Storyboard.TargetName="triangle" Storyboard.TargetProperty="(UIElement.Opacity)" Duration="0:0:0.5" To="1"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Unchecked">
                                    <Storyboard>
                                        <DoubleAnimation Storyboard.TargetName="triangle" Storyboard.TargetProperty="(UIElement.Opacity)" Duration="0:0:0.5" To="0"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>                            
                        </VisualStateManager.VisualStateGroups>

                        <Path x:Name="triangle" Grid.Column="0" Data="M 0,6 8,10 0,14 0,6" 
                              Stroke="#40000000" StrokeThickness="1" StrokeEndLineCap="Round" 
                              StrokeLineJoin="Round" Fill="Black" Opacity="0"/>
                        
                        <ContentPresenter
                                  Grid.Column="1"
                                  x:Name="contentPresenter"
                                  Content="{TemplateBinding Content}"
                                  ContentTemplate="{TemplateBinding ContentTemplate}"
                                  HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                  VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                  Margin="{TemplateBinding Padding}"/>

                        <Rectangle x:Name="contentHighlight" Grid.Column="1" Stroke="Transparent" Fill="#00000000"
                                   HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                   VerticalAlignment="Top"
                                   Margin="{TemplateBinding Padding}"
                                   Width="{TemplateBinding Width}" 
                                   Height="{TemplateBinding Height}"/>
                        
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>


    <!--RADIOBUTTON FOR MAIN MENU-->
    <Style x:Key="MenuRadioButton" TargetType="RadioButton">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="RadioButton">
                    <Grid>
                        <VisualStateManager.VisualStateGroups>
                            
                            <VisualStateGroup x:Name="CheckStates">
                                <VisualState x:Name="Checked">
                                    <Storyboard>
                                        <DoubleAnimation Storyboard.TargetName="contentPresenter" 
                                                         Storyboard.TargetProperty="(UIElement.Opacity)" 
                                                         Duration="0:0:0.4" To="1"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Unchecked">
                                    <Storyboard>
                                        <DoubleAnimation Storyboard.TargetName="contentPresenter" 
                                                         Storyboard.TargetProperty="(UIElement.Opacity)" 
                                                         Duration="0:0:0.4" To="0.25"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            
                        </VisualStateManager.VisualStateGroups>

                        <ContentPresenter
                                      x:Name="contentPresenter"
                                      Content="{TemplateBinding Content}"
                                      ContentTemplate="{TemplateBinding ContentTemplate}"
                                      HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                      VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                      Margin="{TemplateBinding Padding}"/>

                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>


    <!--EXPANDER STYLE-->
	<Style x:Key="OIExpanderStyle" TargetType="toolkit:Expander">
		<Setter Property="BorderThickness" Value="1"/>
		<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
		<Setter Property="VerticalContentAlignment" Value="Stretch"/>
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="toolkit:Expander">
					<Grid Background="Transparent">
						<Grid.Resources>
							<LinearGradientBrush x:Key="ExpanderArrowFill" EndPoint="0,1" StartPoint="0,0">
								<GradientStop Color="White" Offset="0"/>
                                <GradientStop Color="{StaticResource ThemeColor}" Offset="1"/>
							</LinearGradientBrush>
							<LinearGradientBrush x:Key="ExpanderArrowHoverFill" EndPoint="0,1" StartPoint="0,0">
								<GradientStop Color="#FFF0F8FE" Offset="0"/>
                                <GradientStop Color="{StaticResource ThemeColor}" Offset="1"/>
							</LinearGradientBrush>
							<LinearGradientBrush x:Key="ExpanderArrowPressedFill" EndPoint="0,1" StartPoint="0,0">
								<GradientStop Color="#FFDCF0FA" Offset="0"/>
                                <GradientStop Color="{StaticResource ThemeColor}" Offset="1"/>
							</LinearGradientBrush>
							<ControlTemplate x:Key="ExpanderDownHeaderTemplate" TargetType="ToggleButton">
								<Grid Background="Transparent">
									<VisualStateManager.VisualStateGroups>
										<VisualStateGroup x:Name="CheckStates">
											<VisualStateGroup.Transitions>
												<VisualTransition GeneratedDuration="00:00:00"/>
											</VisualStateGroup.Transitions>
											<VisualState x:Name="Checked">
												<Storyboard>
													<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Data" Storyboard.TargetName="arrow">
														<DiscreteObjectKeyFrame KeyTime="0" Value="M 1,4.5 L 4.5,1 L 8,4.5"/>
													</ObjectAnimationUsingKeyFrames>
												</Storyboard>
											</VisualState>
											<VisualState x:Name="Unchecked"/>
										</VisualStateGroup>
										<VisualStateGroup x:Name="CommonStates">
											<VisualStateGroup.Transitions>
												<VisualTransition GeneratedDuration="0"/>
												<VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
												<VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
											</VisualStateGroup.Transitions>
											<VisualState x:Name="Normal"/>
											<VisualState x:Name="MouseOver">
												<Storyboard>
                                                    <ColorAnimation BeginTime="0" To="#FF000000" Storyboard.TargetProperty="(Ellipse.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="circle"/>
													<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(Ellipse.Fill)" Storyboard.TargetName="circle">
														<DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderArrowHoverFill}"/>
													</ObjectAnimationUsingKeyFrames>
													<ColorAnimation BeginTime="0" To="#222" Storyboard.TargetProperty="(Path.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="arrow"/>
												</Storyboard>
											</VisualState>
											<VisualState x:Name="Pressed">
												<Storyboard>
													<ColorAnimation BeginTime="0" To="#FFFFFFFF" Storyboard.TargetProperty="(Ellipse.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="circle"/>
													<DoubleAnimation BeginTime="0" To="1.5" Storyboard.TargetProperty="StrokeThickness" Storyboard.TargetName="circle"/>
													<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(Ellipse.Fill)" Storyboard.TargetName="circle">
														<DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderArrowPressedFill}"/>
													</ObjectAnimationUsingKeyFrames>
                                                    <ColorAnimation BeginTime="0" To="#FFFFFFFF" Storyboard.TargetProperty="(Path.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="arrow"/>
												</Storyboard>
											</VisualState>
										</VisualStateGroup>
										<VisualStateGroup x:Name="FocusStates">
											<VisualState x:Name="Focused">
												<Storyboard>
													<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility" Storyboard.TargetName="FocusVisualElement">
														<DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
													</ObjectAnimationUsingKeyFrames>
												</Storyboard>
											</VisualState>
											<VisualState x:Name="Unfocused"/>
										</VisualStateGroup>
									</VisualStateManager.VisualStateGroups>
									<Border Padding="{TemplateBinding Padding}">
										<Grid Background="Transparent">
											<Grid.ColumnDefinitions>
												<ColumnDefinition Width="19"/>
												<ColumnDefinition Width="*"/>
											</Grid.ColumnDefinitions>
											<Grid HorizontalAlignment="Left" VerticalAlignment="Top">
												<Ellipse x:Name="circle" Fill="{StaticResource ExpanderArrowFill}" HorizontalAlignment="Center" Height="19" Stroke="DarkGray" VerticalAlignment="Center" Width="19"/>
												<Path x:Name="arrow" Data="M 1,1.5 L 4.5,5 L 8,1.5" HorizontalAlignment="Center" Stroke="#666" StrokeThickness="2" VerticalAlignment="Center"/>
											</Grid>
											<ContentPresenter x:Name="header" ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" Grid.Column="1" HorizontalAlignment="Stretch" Margin="4,0,0,0" VerticalAlignment="Center"/>
										</Grid>
									</Border>
									<Rectangle x:Name="FocusVisualElement" IsHitTestVisible="false" Stroke="Transparent" StrokeThickness="1" Visibility="Collapsed"/>
								</Grid>
							</ControlTemplate>
							<ControlTemplate x:Key="ExpanderUpHeaderTemplate" TargetType="ToggleButton">
								<Grid Background="Transparent">
									<VisualStateManager.VisualStateGroups>
										<VisualStateGroup x:Name="CheckStates">
											<VisualStateGroup.Transitions>
												<VisualTransition GeneratedDuration="00:00:00"/>
											</VisualStateGroup.Transitions>
											<VisualState x:Name="Checked">
												<Storyboard>
													<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Data" Storyboard.TargetName="arrow">
														<DiscreteObjectKeyFrame KeyTime="0" Value="M 1,4.5 L 4.5,1 L 8,4.5"/>
													</ObjectAnimationUsingKeyFrames>
												</Storyboard>
											</VisualState>
											<VisualState x:Name="Unchecked"/>
										</VisualStateGroup>
										<VisualStateGroup x:Name="CommonStates">
											<VisualStateGroup.Transitions>
												<VisualTransition GeneratedDuration="0"/>
												<VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
												<VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
											</VisualStateGroup.Transitions>
											<VisualState x:Name="Normal"/>
											<VisualState x:Name="MouseOver">
												<Storyboard>
                                                    <ColorAnimation BeginTime="0" To="#FF000000" Storyboard.TargetProperty="(Ellipse.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="circle"/>
													<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(Ellipse.Fill)" Storyboard.TargetName="circle">
														<DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderArrowHoverFill}"/>
													</ObjectAnimationUsingKeyFrames>
													<ColorAnimation BeginTime="0" To="#222" Storyboard.TargetProperty="(Path.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="arrow"/>
												</Storyboard>
											</VisualState>
											<VisualState x:Name="Pressed">
												<Storyboard>
                                                    <ColorAnimation BeginTime="0" To="#FFFFFFFF" Storyboard.TargetProperty="(Ellipse.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="circle"/>
													<DoubleAnimation BeginTime="0" To="1.5" Storyboard.TargetProperty="StrokeThickness" Storyboard.TargetName="circle"/>
													<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(Ellipse.Fill)" Storyboard.TargetName="circle">
														<DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderArrowPressedFill}"/>
													</ObjectAnimationUsingKeyFrames>
													<ColorAnimation BeginTime="0" To="#FFFFFFFF" Storyboard.TargetProperty="(Path.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="arrow"/>
												</Storyboard>
											</VisualState>
										</VisualStateGroup>
										<VisualStateGroup x:Name="FocusStates">
											<VisualState x:Name="Focused">
												<Storyboard>
													<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility" Storyboard.TargetName="FocusVisualElement">
														<DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
													</ObjectAnimationUsingKeyFrames>
												</Storyboard>
											</VisualState>
											<VisualState x:Name="Unfocused"/>
										</VisualStateGroup>
									</VisualStateManager.VisualStateGroups>
									<Border Padding="{TemplateBinding Padding}">
										<Grid Background="Transparent">
											<Grid.ColumnDefinitions>
												<ColumnDefinition Width="19"/>
												<ColumnDefinition Width="*"/>
											</Grid.ColumnDefinitions>
											<Grid HorizontalAlignment="Left" VerticalAlignment="Top">
												<Grid.RenderTransform>
													<TransformGroup>
														<TransformGroup.Children>
															<TransformCollection>
																<RotateTransform Angle="180" CenterY="9.5" CenterX="9.5"/>
															</TransformCollection>
														</TransformGroup.Children>
													</TransformGroup>
												</Grid.RenderTransform>
												<Ellipse x:Name="circle" Fill="{StaticResource ExpanderArrowFill}" HorizontalAlignment="Center" Height="19" Stroke="DarkGray" VerticalAlignment="Center" Width="19"/>
												<Path x:Name="arrow" Data="M 1,1.5 L 4.5,5 L 8,1.5" HorizontalAlignment="Center" Stroke="#666" StrokeThickness="2" VerticalAlignment="Center"/>
											</Grid>
											<ContentPresenter x:Name="header" ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" Grid.Column="1" HorizontalAlignment="Stretch" Margin="4,0,0,0" VerticalAlignment="Center"/>
										</Grid>
									</Border>
									<Rectangle x:Name="FocusVisualElement" IsHitTestVisible="false" Stroke="Transparent" StrokeThickness="1" Visibility="Collapsed"/>
								</Grid>
							</ControlTemplate>
							<ControlTemplate x:Key="ExpanderLeftHeaderTemplate" TargetType="ToggleButton">
								<Grid Background="Transparent">
									<VisualStateManager.VisualStateGroups>
										<VisualStateGroup x:Name="CheckStates">
											<VisualStateGroup.Transitions>
												<VisualTransition GeneratedDuration="00:00:00"/>
											</VisualStateGroup.Transitions>
											<VisualState x:Name="Checked">
												<Storyboard>
													<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Data" Storyboard.TargetName="arrow">
														<DiscreteObjectKeyFrame KeyTime="0" Value="M 1,4.5 L 4.5,1 L 8,4.5"/>
													</ObjectAnimationUsingKeyFrames>
												</Storyboard>
											</VisualState>
											<VisualState x:Name="Unchecked"/>
										</VisualStateGroup>
										<VisualStateGroup x:Name="CommonStates">
											<VisualStateGroup.Transitions>
												<VisualTransition GeneratedDuration="0"/>
												<VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
												<VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
											</VisualStateGroup.Transitions>
											<VisualState x:Name="Normal"/>
											<VisualState x:Name="MouseOver">
												<Storyboard>
                                                    <ColorAnimation BeginTime="0" To="#FF000000" Storyboard.TargetProperty="(Ellipse.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="circle"/>
													<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(Ellipse.Fill)" Storyboard.TargetName="circle">
														<DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderArrowHoverFill}"/>
													</ObjectAnimationUsingKeyFrames>
													<ColorAnimation BeginTime="0" To="#222" Storyboard.TargetProperty="(Path.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="arrow"/>
												</Storyboard>
											</VisualState>
											<VisualState x:Name="Pressed">
												<Storyboard>
                                                    <ColorAnimation BeginTime="0" To="#FFFFFFFF" Storyboard.TargetProperty="(Ellipse.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="circle"/>
													<DoubleAnimation BeginTime="0" To="1.5" Storyboard.TargetProperty="StrokeThickness" Storyboard.TargetName="circle"/>
													<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(Ellipse.Fill)" Storyboard.TargetName="circle">
														<DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderArrowPressedFill}"/>
													</ObjectAnimationUsingKeyFrames>
													<ColorAnimation BeginTime="0" To="#FFFFFFFF" Storyboard.TargetProperty="(Path.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="arrow"/>
												</Storyboard>
											</VisualState>
										</VisualStateGroup>
										<VisualStateGroup x:Name="FocusStates">
											<VisualState x:Name="Focused">
												<Storyboard>
													<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility" Storyboard.TargetName="FocusVisualElement">
														<DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
													</ObjectAnimationUsingKeyFrames>
												</Storyboard>
											</VisualState>
											<VisualState x:Name="Unfocused"/>
										</VisualStateGroup>
									</VisualStateManager.VisualStateGroups>
									<Border Padding="{TemplateBinding Padding}">
										<Grid Background="Transparent">
											<Grid.RowDefinitions>
												<RowDefinition Height="19"/>
												<RowDefinition Height="*"/>
											</Grid.RowDefinitions>
											<Grid HorizontalAlignment="Center" VerticalAlignment="Top">
												<Grid.RenderTransform>
													<TransformGroup>
														<TransformGroup.Children>
															<TransformCollection>
																<RotateTransform Angle="90" CenterY="9.5" CenterX="9.5"/>
															</TransformCollection>
														</TransformGroup.Children>
													</TransformGroup>
												</Grid.RenderTransform>
												<Ellipse x:Name="circle" Fill="{StaticResource ExpanderArrowFill}" HorizontalAlignment="Center" Height="19" Stroke="DarkGray" VerticalAlignment="Center" Width="19"/>
												<Path x:Name="arrow" Data="M 1,1.5 L 4.5,5 L 8,1.5" HorizontalAlignment="Center" Stroke="#666" StrokeThickness="2" VerticalAlignment="Center"/>
											</Grid>
											<ContentPresenter x:Name="header" ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" HorizontalAlignment="Center" Margin="0,4,0,0" Grid.Row="1" VerticalAlignment="Stretch"/>
										</Grid>
									</Border>
                                    <Rectangle x:Name="FocusVisualElement" IsHitTestVisible="false" Stroke="Transparent" StrokeThickness="1" Visibility="Collapsed"/>
								</Grid>
							</ControlTemplate>
							<ControlTemplate x:Key="ExpanderRightHeaderTemplate" TargetType="ToggleButton">
								<Grid Background="Transparent">
									<VisualStateManager.VisualStateGroups>
										<VisualStateGroup x:Name="CheckStates">
											<VisualStateGroup.Transitions>
												<VisualTransition GeneratedDuration="00:00:00"/>
											</VisualStateGroup.Transitions>
											<VisualState x:Name="Checked">
												<Storyboard>
													<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Data" Storyboard.TargetName="arrow">
														<DiscreteObjectKeyFrame KeyTime="0" Value="M 1,4.5 L 4.5,1 L 8,4.5"/>
													</ObjectAnimationUsingKeyFrames>
												</Storyboard>
											</VisualState>
											<VisualState x:Name="Unchecked"/>
										</VisualStateGroup>
										<VisualStateGroup x:Name="CommonStates">
											<VisualStateGroup.Transitions>
												<VisualTransition GeneratedDuration="0"/>
												<VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
												<VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
											</VisualStateGroup.Transitions>
											<VisualState x:Name="Normal"/>
											<VisualState x:Name="MouseOver">
												<Storyboard>
													<ColorAnimation BeginTime="0" To="#FF000000" Storyboard.TargetProperty="(Ellipse.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="circle"/>
													<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(Ellipse.Fill)" Storyboard.TargetName="circle">
														<DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderArrowHoverFill}"/>
													</ObjectAnimationUsingKeyFrames>
													<ColorAnimation BeginTime="0" To="#222" Storyboard.TargetProperty="(Path.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="arrow"/>
												</Storyboard>
											</VisualState>
											<VisualState x:Name="Pressed">
												<Storyboard>
                                                    <ColorAnimation BeginTime="0" To="#FFFFFFFF" Storyboard.TargetProperty="(Ellipse.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="circle"/>
													<DoubleAnimation BeginTime="0" To="1.5" Storyboard.TargetProperty="StrokeThickness" Storyboard.TargetName="circle"/>
													<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(Ellipse.Fill)" Storyboard.TargetName="circle">
														<DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderArrowPressedFill}"/>
													</ObjectAnimationUsingKeyFrames>
													<ColorAnimation BeginTime="0" To="#FFFFFFFF" Storyboard.TargetProperty="(Path.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="arrow"/>
												</Storyboard>
											</VisualState>
										</VisualStateGroup>
										<VisualStateGroup x:Name="FocusStates">
											<VisualState x:Name="Focused">
												<Storyboard>
													<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility" Storyboard.TargetName="FocusVisualElement">
														<DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
													</ObjectAnimationUsingKeyFrames>
												</Storyboard>
											</VisualState>
											<VisualState x:Name="Unfocused"/>
										</VisualStateGroup>
									</VisualStateManager.VisualStateGroups>
									<Border Padding="{TemplateBinding Padding}">
										<Grid Background="Transparent">
											<Grid.RowDefinitions>
												<RowDefinition Height="19"/>
												<RowDefinition Height="*"/>
											</Grid.RowDefinitions>
											<Grid HorizontalAlignment="Center" VerticalAlignment="Top">
												<Grid.RenderTransform>
													<TransformGroup>
														<TransformGroup.Children>
															<TransformCollection>
																<RotateTransform Angle="270" CenterY="9.5" CenterX="9.5"/>
															</TransformCollection>
														</TransformGroup.Children>
													</TransformGroup>
												</Grid.RenderTransform>
												<Ellipse x:Name="circle" Fill="{StaticResource ExpanderArrowFill}" HorizontalAlignment="Center" Height="19" Stroke="DarkGray" VerticalAlignment="Center" Width="19"/>
												<Path x:Name="arrow" Data="M 1,1.5 L 4.5,5 L 8,1.5" HorizontalAlignment="Center" Stroke="#666" StrokeThickness="2" VerticalAlignment="Center"/>
											</Grid>
											<ContentPresenter x:Name="header" ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" HorizontalAlignment="Center" Margin="0,4,0,0" Grid.Row="1" VerticalAlignment="Stretch"/>
										</Grid>
									</Border>
                                    <Rectangle x:Name="FocusVisualElement" IsHitTestVisible="false" Stroke="Transparent" StrokeThickness="1" Visibility="Collapsed"/>
								</Grid>
							</ControlTemplate>
						</Grid.Resources>
						<VisualStateManager.VisualStateGroups>
							<VisualStateGroup x:Name="CommonStates">
								<VisualStateGroup.Transitions>
									<VisualTransition GeneratedDuration="0"/>
								</VisualStateGroup.Transitions>
								<VisualState x:Name="Normal"/>
								<VisualState x:Name="Disabled">
									<Storyboard>
										<DoubleAnimation Duration="0" To="1" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="DisabledVisualElement"/>
									</Storyboard>
								</VisualState>
							</VisualStateGroup>
							<VisualStateGroup x:Name="FocusStates">
								<VisualState x:Name="Focused">
									<Storyboard>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility" Storyboard.TargetName="FocusVisualElement">
											<DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
										</ObjectAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Unfocused"/>
							</VisualStateGroup>
							<VisualStateGroup x:Name="ExpansionStates">
								<VisualStateGroup.Transitions>
									<VisualTransition GeneratedDuration="0"/>
								</VisualStateGroup.Transitions>
								<VisualState x:Name="Collapsed"/>
								<VisualState x:Name="Expanded">
									<Storyboard>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility" Storyboard.TargetName="ExpandSite">
											<DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
										</ObjectAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
							</VisualStateGroup>
							<VisualStateGroup x:Name="ExpandDirectionStates">
								<VisualStateGroup.Transitions>
									<VisualTransition GeneratedDuration="0"/>
								</VisualStateGroup.Transitions>
								<VisualState x:Name="ExpandDown">
									<Storyboard>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Height" Storyboard.TargetName="rd1">
											<DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Width" Storyboard.TargetName="cd0">
											<DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
										</ObjectAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="ExpandUp">
									<Storyboard>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Template" Storyboard.TargetName="ExpanderButton">
											<DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderUpHeaderTemplate}"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="(Grid.Row)" Storyboard.TargetName="ExpanderButton">
											<DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="(Grid.Row)" Storyboard.TargetName="ExpandSite">
											<DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Height" Storyboard.TargetName="rd0">
											<DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Width" Storyboard.TargetName="cd0">
											<DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
										</ObjectAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="ExpandLeft">
									<Storyboard>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Template" Storyboard.TargetName="ExpanderButton">
											<DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderLeftHeaderTemplate}"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="(Grid.Column)" Storyboard.TargetName="ExpanderButton">
											<DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="(Grid.Row)" Storyboard.TargetName="ExpandSite">
											<DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Height" Storyboard.TargetName="rd0">
											<DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Width" Storyboard.TargetName="cd0">
											<DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
										</ObjectAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="ExpandRight">
									<Storyboard>
										<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Template" Storyboard.TargetName="ExpanderButton">
											<DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderRightHeaderTemplate}"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="(Grid.Row)" Storyboard.TargetName="ExpandSite">
											<DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="(Grid.Column)" Storyboard.TargetName="ExpandSite">
											<DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Height" Storyboard.TargetName="rd0">
											<DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Width" Storyboard.TargetName="cd1">
											<DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
										</ObjectAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
							</VisualStateGroup>
						</VisualStateManager.VisualStateGroups>
						<Border x:Name="Background" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" CornerRadius="3">
							<Grid>
								<Grid.ColumnDefinitions>
									<ColumnDefinition x:Name="cd0" Width="Auto"/>
									<ColumnDefinition x:Name="cd1" Width="Auto"/>
								</Grid.ColumnDefinitions>
								<Grid.RowDefinitions>
									<RowDefinition x:Name="rd0" Height="Auto"/>
									<RowDefinition x:Name="rd1" Height="Auto"/>
								</Grid.RowDefinitions>
								<ToggleButton x:Name="ExpanderButton" ContentTemplate="{TemplateBinding HeaderTemplate}" Content="{TemplateBinding Header}" Grid.Column="0" Foreground="{TemplateBinding Foreground}" FontWeight="{TemplateBinding FontWeight}" FontStyle="{TemplateBinding FontStyle}" FontStretch="{TemplateBinding FontStretch}" FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" IsChecked="{TemplateBinding IsExpanded}" Margin="1" MinWidth="0" MinHeight="0" Padding="{TemplateBinding Padding}" Grid.Row="0" Template="{StaticResource ExpanderDownHeaderTemplate}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}"/>
								<ContentControl x:Name="ExpandSite" ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" Grid.Column="0" Foreground="{TemplateBinding Foreground}" FontWeight="{TemplateBinding FontWeight}" FontStyle="{TemplateBinding FontStyle}" FontStretch="{TemplateBinding FontStretch}" FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" Grid.Row="1" Visibility="Collapsed" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}"/>
							</Grid>
						</Border>
						<Border x:Name="DisabledVisualElement" Background="#A5FFFFFF" CornerRadius="3" IsHitTestVisible="false" Opacity="0"/>
						<Border x:Name="FocusVisualElement" BorderThickness="0" CornerRadius="3" IsHitTestVisible="false" Visibility="Collapsed">
							<Border.BorderBrush>
								<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
									<GradientStop Color="#FFA3AEB9"/>
									<GradientStop Color="#FF8399A9" Offset="0.375"/>
									<GradientStop Color="#FF718597" Offset="0.375"/>
									<GradientStop Color="#FF617584" Offset="1"/>
								</LinearGradientBrush>
							</Border.BorderBrush>
						</Border>
					</Grid>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>
    
    
    <!--ACCORDIAN BUTTON FOR TOOLBOX ITEMS-->
	<Style x:Key="OIAccordionButtonStyle" TargetType="toolkit:AccordionButton">
		<Setter Property="BorderThickness" Value="0"/>
		<Setter Property="Background" Value="White"/>
		<Setter Property="HorizontalAlignment" Value="Stretch"/>
		<Setter Property="VerticalAlignment" Value="Stretch"/>
		<Setter Property="HorizontalContentAlignment" Value="Center"/>
		<Setter Property="VerticalContentAlignment" Value="Center"/>
		<Setter Property="IsTabStop" Value="True"/>
		<Setter Property="TabNavigation" Value="Once"/>
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="toolkit:AccordionButton">
					<Grid Background="Transparent" Margin="{TemplateBinding Padding}">
						<VisualStateManager.VisualStateGroups>
							<VisualStateGroup x:Name="ExpandDirectionStates">
								<VisualStateGroup.Transitions>
									<VisualTransition GeneratedDuration="0"/>
								</VisualStateGroup.Transitions>
								<VisualState x:Name="ExpandDown">
									<Storyboard>
										<ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetProperty="(Grid.Column)" Storyboard.TargetName="icon">
											<DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetProperty="(Grid.Row)" Storyboard.TargetName="icon">
											<DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetProperty="(Grid.Column)" Storyboard.TargetName="header">
											<DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetProperty="(Grid.Row)" Storyboard.TargetName="header">
											<DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetProperty="Width" Storyboard.TargetName="cd0">
											<DiscreteObjectKeyFrame KeyTime="0" Value="Auto"/>
										</ObjectAnimationUsingKeyFrames>
										<ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetProperty="Width" Storyboard.TargetName="cd1">
											<DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
										</ObjectAnimationUsingKeyFrames>
										<DoubleAnimation BeginTime="00:00:00" Duration="00:00:00" To="-90" 
                                                         Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" Storyboard.TargetName="arrow"/>
									</Storyboard>
								</VisualState>
							</VisualStateGroup>
							<VisualStateGroup x:Name="ExpansionStates">
								<VisualStateGroup.Transitions>
									<VisualTransition GeneratedDuration="0"/>
								</VisualStateGroup.Transitions>
								<VisualState x:Name="Collapsed">
									<Storyboard>
										<DoubleAnimation BeginTime="00:00:00" Duration="00:00:00.3" To="0" 
                                                         Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)"
                                                         Storyboard.TargetName="icon"/>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Expanded">
									<Storyboard>
										<DoubleAnimation BeginTime="00:00:00" Duration="00:00:00.3" To="90" 
                                                         Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" 
                                                         Storyboard.TargetName="icon"/>
										<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(Border.Background).(SolidColorBrush.Color)" 
                                                                      Storyboard.TargetName="ExpandedBackground">
                                            <SplineColorKeyFrame KeyTime="00:00:00" Value="{StaticResource ThemeColor}"/>
										</ColorAnimationUsingKeyFrames>
										<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(UIElement.Opacity)" 
                                                                       Storyboard.TargetName="ExpandedBackground">
											<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.5"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
							</VisualStateGroup>
							<VisualStateGroup x:Name="CheckStates">
								<VisualStateGroup.Transitions>
									<VisualTransition GeneratedDuration="00:00:00"/>
								</VisualStateGroup.Transitions>
								<VisualState x:Name="Checked"/>
								<VisualState x:Name="Unchecked"/>
							</VisualStateGroup>
							<VisualStateGroup x:Name="CommonStates">
								<VisualStateGroup.Transitions>
									<VisualTransition GeneratedDuration="0"/>
									<VisualTransition From="MouseOver" GeneratedDuration="00:00:00.1" To="Normal"/>
									<VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
									<VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
								</VisualStateGroup.Transitions>
								<VisualState x:Name="Normal"/>
								<VisualState x:Name="MouseOver">
									<Storyboard>
										<ColorAnimation BeginTime="0" To="#222" Storyboard.TargetProperty="(Path.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="arrow"/>
										<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(Border.Background).(SolidColorBrush.Color)" 
                                                                      Storyboard.TargetName="MouseOverBackground">
											<SplineColorKeyFrame KeyTime="00:00:00" Value="{StaticResource ThemeColor}"/>
										</ColorAnimationUsingKeyFrames>
										<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(UIElement.Opacity)" 
                                                                       Storyboard.TargetName="MouseOverBackground">
											<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.3"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Pressed">
									<Storyboard>
										<ColorAnimation BeginTime="0" To="#FF000000" Storyboard.TargetProperty="(Path.Stroke).(SolidColorBrush.Color)" Storyboard.TargetName="arrow"/>
										<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(Border.Background).(SolidColorBrush.Color)" 
                                                                      Storyboard.TargetName="MouseOverBackground">
											<SplineColorKeyFrame KeyTime="00:00:00" Value="Transparent"/>
										</ColorAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Disabled">
									<Storyboard/>
								</VisualState>
							</VisualStateGroup>
							<VisualStateGroup x:Name="FocusStates">
								<VisualState x:Name="Focused">
									<Storyboard>
										<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility" Storyboard.TargetName="FocusVisualElement">
											<DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
										</ObjectAnimationUsingKeyFrames>
										<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(UIElement.Opacity)" 
                                                                       Storyboard.TargetName="FocusVisualElement">
											<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.385"/>
										</DoubleAnimationUsingKeyFrames>
									</Storyboard>
								</VisualState>
								<VisualState x:Name="Unfocused"/>
							</VisualStateGroup>
						</VisualStateManager.VisualStateGroups>
						<Border x:Name="background" Background="{TemplateBinding Background}" CornerRadius="1,1,1,1">
							<Grid>
                                <Border x:Name="ExpandedBackground" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" 
                                        Background="Transparent" CornerRadius="1,1,1,1" Height="Auto" Margin="0,0,0,0" Opacity="0" VerticalAlignment="Stretch"/>
								<Border x:Name="MouseOverBackground" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" 
                                        Opacity="0" Background="{StaticResource ThemeColorBrush}" CornerRadius="1,1,1,1" Height="Auto" Margin="0,0,0,0" VerticalAlignment="Stretch"/>
								<Grid Background="Transparent">
									<Grid.ColumnDefinitions>
										<ColumnDefinition x:Name="cd0" Width="Auto"/>
										<ColumnDefinition x:Name="cd1" Width="Auto"/>
									</Grid.ColumnDefinitions>
									<Grid.RowDefinitions>
										<RowDefinition x:Name="rd0" Height="Auto"/>
										<RowDefinition x:Name="rd1" Height="Auto"/>
									</Grid.RowDefinitions>
									<Grid x:Name="icon" Grid.Column="0" HorizontalAlignment="Center" Height="19" Grid.Row="0" RenderTransformOrigin="0.5,0.5" VerticalAlignment="Center" Width="19">
										<Grid.RenderTransform>
											<TransformGroup>
												<ScaleTransform/>
												<SkewTransform/>
												<RotateTransform Angle="-90"/>
												<TranslateTransform/>
											</TransformGroup>
										</Grid.RenderTransform>
										<Path x:Name="arrow" Data="M 1,1.5 L 4.5,5 L 8,1.5" HorizontalAlignment="Center" Height="Auto" Margin="0,0,0,0" RenderTransformOrigin="0.5,0.5" Stroke="#666" StrokeThickness="2" VerticalAlignment="Center" Width="Auto">
											<Path.RenderTransform>
												<TransformGroup>
													<ScaleTransform/>
													<SkewTransform/>
													<RotateTransform/>
													<TranslateTransform/>
												</TransformGroup>
											</Path.RenderTransform>
										</Path>
									</Grid>
									<toolkit:LayoutTransformer x:Name="header" ContentTemplate="{TemplateBinding ContentTemplate}" 
                                                               Content="{TemplateBinding Content}" Grid.Column="1" Foreground="{TemplateBinding Foreground}" 
                                                               FontWeight="{TemplateBinding FontWeight}" FontStyle="{TemplateBinding FontStyle}" FontStretch="{TemplateBinding FontStretch}" 
                                                               FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" 
                                                               HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="6,2,0,0" Grid.Row="0" Grid.RowSpan="1"/>
								</Grid>
							</Grid>
						</Border>
						<Rectangle x:Name="FocusVisualElement" IsHitTestVisible="false" RadiusY="1" RadiusX="1" Stroke="Transparent" StrokeThickness="1" Visibility="Collapsed"/>
					</Grid>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>


    <!--ACCORDIAN BUTTON FOR LEGEND ITEMS-->
    <Style x:Key="OIAccordionButtonStyleLegend" TargetType="toolkit:AccordionButton">
        <Setter Property="BorderThickness" Value="0"/>
        <Setter Property="Background" Value="White"/>
        <Setter Property="HorizontalAlignment" Value="Stretch"/>
        <Setter Property="VerticalAlignment" Value="Stretch"/>
        <Setter Property="HorizontalContentAlignment" Value="Center"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="IsTabStop" Value="True"/>
        <Setter Property="TabNavigation" Value="Once"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="toolkit:AccordionButton">
                    <Grid Background="Transparent" Margin="{TemplateBinding Padding}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="ExpandDirectionStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="0"/>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="ExpandDown">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetProperty="(Grid.Column)" Storyboard.TargetName="icon">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetProperty="(Grid.Row)" Storyboard.TargetName="icon">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetProperty="(Grid.Column)" Storyboard.TargetName="header">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetProperty="(Grid.Row)" Storyboard.TargetName="header">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetProperty="Width" Storyboard.TargetName="cd0">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Auto"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetProperty="Width" Storyboard.TargetName="cd1">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <DoubleAnimation BeginTime="00:00:00" Duration="00:00:00" To="-90" 
                                                         Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" Storyboard.TargetName="arrow"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            
                            <VisualStateGroup x:Name="ExpansionStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="0"/>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Collapsed">
                                    <Storyboard>
                                        <DoubleAnimation BeginTime="00:00:00" Duration="00:00:00.3" To="0" 
                                                         Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)"
                                                         Storyboard.TargetName="icon"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Expanded">
                                    <Storyboard>
                                        <DoubleAnimation BeginTime="00:00:00" Duration="00:00:00.3" To="90" 
                                                         Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" 
                                                         Storyboard.TargetName="icon"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            
                            <VisualStateGroup x:Name="CheckStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="00:00:00"/>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Checked"/>
                                <VisualState x:Name="Unchecked"/>
                            </VisualStateGroup>
                            
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal"/>
                                <VisualState x:Name="MouseOver"/>
                                <VisualState x:Name="Pressed"/>
                                <VisualState x:Name="Disabled"/>
                            </VisualStateGroup>
                            
                            <VisualStateGroup x:Name="FocusStates"/>
                        </VisualStateManager.VisualStateGroups>
                                
                        <Border x:Name="background" Background="{TemplateBinding Background}" CornerRadius="1,1,1,1">
                            <Grid>
                                <Border x:Name="ExpandedBackground" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" 
                                        Background="Transparent" CornerRadius="1,1,1,1" Height="Auto" Margin="0,0,0,0" Opacity="0" VerticalAlignment="Stretch"/>
                                
                                <Grid Background="Transparent">
                                    <Grid.ColumnDefinitions>
                                        <ColumnDefinition x:Name="cd0" Width="Auto"/>
                                        <ColumnDefinition x:Name="cd1" Width="Auto"/>
                                    </Grid.ColumnDefinitions>
                                    <Grid.RowDefinitions>
                                        <RowDefinition x:Name="rd0" Height="Auto"/>
                                        <RowDefinition x:Name="rd1" Height="Auto"/>
                                    </Grid.RowDefinitions>
                                    <Grid x:Name="icon" Grid.Column="0" HorizontalAlignment="Center" Height="19" Grid.Row="0" RenderTransformOrigin="0.5,0.5" VerticalAlignment="Center" Width="19">
                                        <Grid.RenderTransform>
                                            <TransformGroup>
                                                <ScaleTransform/>
                                                <SkewTransform/>
                                                <RotateTransform Angle="-90"/>
                                                <TranslateTransform/>
                                            </TransformGroup>
                                        </Grid.RenderTransform>
                                        <Path x:Name="arrow" Data="M 1,1.5 L 4.5,5 L 8,1.5" HorizontalAlignment="Center" Height="Auto" Margin="0,0,0,0" RenderTransformOrigin="0.5,0.5" Stroke="#666" StrokeThickness="2" VerticalAlignment="Center" Width="Auto">
                                            <Path.RenderTransform>
                                                <TransformGroup>
                                                    <ScaleTransform/>
                                                    <SkewTransform/>
                                                    <RotateTransform/>
                                                    <TranslateTransform/>
                                                </TransformGroup>
                                            </Path.RenderTransform>
                                        </Path>
                                    </Grid>
                                    <toolkit:LayoutTransformer x:Name="header" ContentTemplate="{TemplateBinding ContentTemplate}" 
                                                               Content="{TemplateBinding Content}" Grid.Column="1" Foreground="{TemplateBinding Foreground}" 
                                                               FontWeight="{TemplateBinding FontWeight}" FontStyle="{TemplateBinding FontStyle}" FontStretch="{TemplateBinding FontStretch}" 
                                                               FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" 
                                                               HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="6,2,0,0" Grid.Row="0" Grid.RowSpan="1"/>
                                </Grid>
                            </Grid>
                        </Border>
                        
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!--DATAGRID STYLE-->
    <Style x:Key="OIDataGridStyle" TargetType="sdk:DataGrid">
        <Setter Property="RowBackground" Value="#00FFFFFF"/>
        <Setter Property="AlternatingRowBackground" Value="#00FFFFFF"/>
        <Setter Property="Background" Value="#FFFFFFFF"/>
        <Setter Property="HeadersVisibility" Value="Column"/>
        <Setter Property="HorizontalScrollBarVisibility" Value="Auto"/>
        <Setter Property="VerticalScrollBarVisibility" Value="Auto"/>
        <Setter Property="SelectionMode" Value="Extended"/>
        <Setter Property="CanUserReorderColumns" Value="True"/>
        <Setter Property="CanUserResizeColumns" Value="True"/>
        <Setter Property="CanUserSortColumns" Value="True"/>
        <Setter Property="AutoGenerateColumns" Value="True"/>
        <Setter Property="RowDetailsVisibilityMode" Value="VisibleWhenSelected"/>
        <Setter Property="BorderBrush">
            <Setter.Value>
                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                    <GradientStop Color="#FFA3AEB9" Offset="0"/>
                    <GradientStop Color="#FF8399A9" Offset="0.375"/>
                    <GradientStop Color="#FF718597" Offset="0.375"/>
                    <GradientStop Color="#FF617584" Offset="1"/>
                </LinearGradientBrush>
            </Setter.Value>
        </Setter>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="DragIndicatorStyle">
            <Setter.Value>
                <Style TargetType="ContentControl">
                    <Setter Property="Foreground" Value="#7FFFFFFF"/>
                    <Setter Property="Template">
                        <Setter.Value>
                            <ControlTemplate TargetType="ContentControl">
                                <Grid>
                                    <VisualStateManager.VisualStateGroups>
                                        <VisualStateGroup x:Name="SortStates">
                                            <VisualState x:Name="Unsorted"/>
                                            <VisualState x:Name="SortAscending">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" To="1.0" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="SortIcon"/>
                                                </Storyboard>
                                            </VisualState>
                                            <VisualState x:Name="SortDescending">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" To="1.0" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="SortIcon"/>
                                                    <DoubleAnimation Duration="0" To="-.9" Storyboard.TargetProperty="(RenderTransform).ScaleY" Storyboard.TargetName="SortIcon"/>
                                                </Storyboard>
                                            </VisualState>
                                        </VisualStateGroup>
                                    </VisualStateManager.VisualStateGroups>
                                    <Rectangle x:Name="BackgroundRectangle" Grid.ColumnSpan="2" Fill="#66808080" Stretch="Fill"/>
                                    <Rectangle x:Name="BackgroundGradient" Grid.ColumnSpan="2" Opacity="0" Stretch="Fill">
                                        <Rectangle.Fill>
                                            <LinearGradientBrush EndPoint=".7,1" StartPoint=".7,0">
                                                <GradientStop Color="#FFFFFFFF" Offset="0.015"/>
                                                <GradientStop Color="#F9FFFFFF" Offset="0.375"/>
                                                <GradientStop Color="#E5FFFFFF" Offset="0.6"/>
                                                <GradientStop Color="#C6FFFFFF" Offset="1"/>
                                            </LinearGradientBrush>
                                        </Rectangle.Fill>
                                    </Rectangle>
                                    <Grid HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" 
                                          VerticalAlignment="{TemplateBinding VerticalContentAlignment}">
                                        <Grid.ColumnDefinitions>
                                            <ColumnDefinition/>
                                            <ColumnDefinition Width="Auto"/>
                                        </Grid.ColumnDefinitions>
                                        <ContentPresenter Content="{TemplateBinding Content}"/>
                                        <Path x:Name="SortIcon" Grid.Column="1" Data="F1 M -5.215,6.099L 5.215,6.099L 0,0L -5.215,6.099 Z " Fill="#7FFFFFFF" 
                                              HorizontalAlignment="Left" Margin="4,0,0,0" Opacity="0" RenderTransformOrigin=".5,.5" Stretch="Uniform" VerticalAlignment="Center" Width="8">
                                            <Path.RenderTransform>
                                                <ScaleTransform ScaleY=".9" ScaleX=".9"/>
                                            </Path.RenderTransform>
                                        </Path>
                                    </Grid>
                                </Grid>
                            </ControlTemplate>
                        </Setter.Value>
                    </Setter>
                </Style>
            </Setter.Value>
        </Setter>
        <Setter Property="DropLocationIndicatorStyle">
            <Setter.Value>
                <Style TargetType="ContentControl">
                    <Setter Property="Background" Value="#FF3F4346"/>
                    <Setter Property="Width" Value="2"/>
                    <Setter Property="Template">
                        <Setter.Value>
                            <ControlTemplate TargetType="ContentControl">
                                <Rectangle Fill="{TemplateBinding Background}" Height="{TemplateBinding Height}" Width="{TemplateBinding Width}"/>
                            </ControlTemplate>
                        </Setter.Value>
                    </Setter>
                </Style>
            </Setter.Value>
        </Setter>
        <Setter Property="GridLinesVisibility" Value="Vertical"/>
        <Setter Property="HorizontalGridLinesBrush" Value="#FFC9CACA"/>
        <Setter Property="IsTabStop" Value="True"/>
        <Setter Property="VerticalGridLinesBrush" Value="#FFC9CACA"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="sdk:DataGrid">
                    <Grid>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal"/>
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" To="1" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="DisabledVisualElement"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Border BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2">
                            <Grid x:Name="Root" Background="{TemplateBinding Background}">
                                <Grid.Resources>
                                    <ControlTemplate x:Key="TopLeftHeaderTemplate" TargetType="sdk1:DataGridColumnHeader">
                                        <Grid x:Name="Root">
                                            <Grid.RowDefinitions>
                                                <RowDefinition/>
                                                <RowDefinition/>
                                                <RowDefinition Height="Auto"/>
                                            </Grid.RowDefinitions>
                                            <Border BorderBrush="#FFC9CACA" BorderThickness="0,0,1,0" Background="#FF1F3B53" Grid.RowSpan="2">
                                                <Rectangle Stretch="Fill" StrokeThickness="1">
                                                    <Rectangle.Fill>
                                                        <LinearGradientBrush EndPoint=".7,1" StartPoint=".7,0">
                                                            <GradientStop Color="#FCFFFFFF" Offset="0.015"/>
                                                            <GradientStop Color="#F7FFFFFF" Offset="0.375"/>
                                                            <GradientStop Color="#E5FFFFFF" Offset="0.6"/>
                                                            <GradientStop Color="#D1FFFFFF" Offset="1"/>
                                                        </LinearGradientBrush>
                                                    </Rectangle.Fill>
                                                </Rectangle>
                                            </Border>
                                            <Rectangle Fill="#FFDBDCDC" Height="1" Grid.RowSpan="2" StrokeThickness="1" VerticalAlignment="Bottom" Width="Auto"/>
                                        </Grid>
                                    </ControlTemplate>
                                    <ControlTemplate x:Key="TopRightHeaderTemplate" TargetType="sdk1:DataGridColumnHeader">
                                        <Grid x:Name="RootElement">
                                            <Grid.RowDefinitions>
                                                <RowDefinition/>
                                                <RowDefinition/>
                                                <RowDefinition Height="Auto"/>
                                            </Grid.RowDefinitions>
                                            <Border BorderBrush="#FFC9CACA" BorderThickness="1,0,0,0" Background="#FF1F3B53" Grid.RowSpan="2">
                                                <Rectangle Stretch="Fill">
                                                    <Rectangle.Fill>
                                                        <LinearGradientBrush EndPoint=".7,1" StartPoint=".7,0">
                                                            <GradientStop Color="#FCFFFFFF" Offset="0.015"/>
                                                            <GradientStop Color="#F7FFFFFF" Offset="0.375"/>
                                                            <GradientStop Color="#E5FFFFFF" Offset="0.6"/>
                                                            <GradientStop Color="#D1FFFFFF" Offset="1"/>
                                                        </LinearGradientBrush>
                                                    </Rectangle.Fill>
                                                </Rectangle>
                                            </Border>
                                        </Grid>
                                    </ControlTemplate>
                                </Grid.Resources>
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="Auto"/>
                                    <ColumnDefinition/>
                                    <ColumnDefinition Width="Auto"/>
                                </Grid.ColumnDefinitions>
                                <Grid.RowDefinitions>
                                    <RowDefinition Height="Auto"/>
                                    <RowDefinition/>
                                    <RowDefinition Height="Auto"/>
                                    <RowDefinition Height="Auto"/>
                                </Grid.RowDefinitions>
                                <sdk1:DataGridColumnHeader x:Name="TopLeftCornerHeader" Template="{StaticResource TopLeftHeaderTemplate}" Width="22"/>
                                <sdk1:DataGridColumnHeadersPresenter x:Name="ColumnHeadersPresenter" Grid.Column="1"  
                                                                     Micro:Message.Attach="[Event MouseEnter] = [Action SortColMouseEnter()];[Event MouseLeave] = [Action SortColMouseLeave()]" />
                                <sdk1:DataGridColumnHeader x:Name="TopRightCornerHeader" Grid.Column="2" Template="{StaticResource TopRightHeaderTemplate}"/>
                                <Rectangle x:Name="ColumnHeadersAndRowsSeparator" Grid.ColumnSpan="3" Fill="#FFC9CACA" Height="1" StrokeThickness="1" VerticalAlignment="Bottom" Width="Auto"/>
                                <sdk1:DataGridRowsPresenter x:Name="RowsPresenter" Grid.ColumnSpan="2" Grid.Row="1"/>
                                <Rectangle x:Name="BottomRightCorner" Grid.Column="2" Fill="#FFE9EEF4" Grid.Row="2"/>
                                <Rectangle x:Name="BottomLeftCorner" Grid.ColumnSpan="2" Fill="#FFE9EEF4" Grid.Row="2"/>
                                <ScrollBar x:Name="VerticalScrollbar" Grid.Column="2" Margin="0,-1,-1,-1" Orientation="Vertical" Grid.Row="1" Width="18"/>
                                <Grid Grid.Column="1" Grid.Row="2">
                                    <Grid.ColumnDefinitions>
                                        <ColumnDefinition Width="Auto"/>
                                        <ColumnDefinition/>
                                    </Grid.ColumnDefinitions>
                                    <Rectangle x:Name="FrozenColumnScrollBarSpacer"/>
                                    <ScrollBar x:Name="HorizontalScrollbar" Grid.Column="1" Height="18" Margin="-1,0,-1,-1" Orientation="Horizontal"/>
                                </Grid>
                                <Controls:ValidationSummary x:Name="ValidationSummary" Grid.ColumnSpan="3" MaxHeight="90" Grid.Row="3"/>
                            </Grid>
                        </Border>
                        <Border x:Name="DisabledVisualElement" Background="#8CFFFFFF" CornerRadius="2" HorizontalAlignment="Stretch" Height="Auto" IsHitTestVisible="False" Opacity="0" VerticalAlignment="Stretch" Width="Auto"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!--DATAGRID ROW STYLE-->
    <Style x:Key="OIDataGridRowStyle" TargetType="sdk:DataGridRow">
        <Setter Property="IsTabStop" Value="False" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="sdk:DataGridRow">
                    <sdk1:DataGridFrozenGrid x:Name="Root">
                        <sdk1:DataGridFrozenGrid.Resources>
                            <Storyboard x:Key="DetailsVisibleTransition">
                                <DoubleAnimation Storyboard.TargetName="DetailsPresenter" Storyboard.TargetProperty="ContentHeight" Duration="00:00:0.1" />
                            </Storyboard>
                        </sdk1:DataGridFrozenGrid.Resources>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="0" />
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="Normal AlternatingRow">
                                    <Storyboard>
                                        <DoubleAnimation Storyboard.TargetName="BackgroundRectangle" Storyboard.TargetProperty="Opacity" Duration="0" To="0"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Storyboard.TargetName="BackgroundRectangle" Storyboard.TargetProperty="Opacity" Duration="0" To="0.15"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Normal Selected">
                                    <Storyboard>
                                        <DoubleAnimation Storyboard.TargetName="BackgroundRectangle" Storyboard.TargetProperty="Opacity" Duration="0" To="0.5"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="MouseOver Selected">
                                    <Storyboard>
                                        <DoubleAnimation Storyboard.TargetName="BackgroundRectangle" Storyboard.TargetProperty="Opacity" Duration="0" To="0.35"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Unfocused Selected">
                                    <Storyboard>
                                        <DoubleAnimation Storyboard.TargetName="BackgroundRectangle" Storyboard.TargetProperty="Opacity" Duration="0" To="0.5"/>
                                        <ColorAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="BackgroundRectangle" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)">
                                            <SplineColorKeyFrame KeyTime="0" Value="#FFE1E7EC"/>
                                        </ColorAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <sdk1:DataGridFrozenGrid.RowDefinitions>
                            <RowDefinition Height="*"/>
                            <RowDefinition Height="Auto"/>
                            <RowDefinition Height="Auto"/>
                        </sdk1:DataGridFrozenGrid.RowDefinitions>
                        <sdk1:DataGridFrozenGrid.ColumnDefinitions>
                            <ColumnDefinition Width="Auto" />
                            <ColumnDefinition Width="*" />
                        </sdk1:DataGridFrozenGrid.ColumnDefinitions>
                        <Rectangle x:Name="BackgroundRectangle" Grid.RowSpan="2" Grid.ColumnSpan="2"
                                   Opacity="0" Fill="{StaticResource ThemeColorBrush}"/>
                        <sdk1:DataGridRowHeader Grid.RowSpan="3" x:Name="RowHeader" sdk1:DataGridFrozenGrid.IsFrozen="True" />
                        <sdk1:DataGridCellsPresenter Grid.Column="1" x:Name="CellsPresenter" 
                                                      Micro:Message.Attach="[Event MouseEnter] = [Action GridRowMouseEnter($dataContext)];[Event MouseLeave] = [Action GridRowMouseLeave($dataContext)]"
                                                     sdk1:DataGridFrozenGrid.IsFrozen="True" />
                        <sdk1:DataGridDetailsPresenter Grid.Row="1" Grid.Column="1" x:Name="DetailsPresenter" />
                        <Rectangle Grid.Row="2" Grid.Column="1" x:Name="BottomGridLine" HorizontalAlignment="Stretch" Height="1" />
                    </sdk1:DataGridFrozenGrid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>


    <!--DATAGRID CELL STYLE-->
    <Style x:Key="OIDataGridCellStyle" TargetType="sdk:DataGridCell">
        <Setter Property="Background" Value="Transparent" />
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalContentAlignment" Value="Stretch" />
        <Setter Property="IsTabStop" Value="False" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="sdk:DataGridCell">
                    <Grid x:Name="Root" Background="{TemplateBinding Background}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CurrentStates">
                                <VisualState x:Name="Regular" />
                                <VisualState x:Name="Current">
                                    <Storyboard>
                                        <DoubleAnimation Storyboard.TargetName="FocusVisual" Storyboard.TargetProperty="Opacity" To="1" Duration="0" />
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ValidationStates">
                                <VisualState x:Name="Valid"/>
                                <VisualState x:Name="Invalid">
                                    <Storyboard>
                                        <DoubleAnimation Storyboard.TargetName="InvalidVisualElement" Storyboard.TargetProperty="Opacity" Duration="0" To="1"/>
                                        <ColorAnimation Storyboard.TargetName="FocusVisual" Storyboard.TargetProperty="(Fill).Color" Duration="0" To="#FFFFFFFF"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>

                        <Grid.ColumnDefinitions>
                            <ColumnDefinition />
                            <ColumnDefinition Width="Auto" />
                        </Grid.ColumnDefinitions>

                        <Rectangle x:Name="FocusVisual" Stroke="Transparent" StrokeThickness="1" Fill="Transparent" HorizontalAlignment="Stretch" 
                               VerticalAlignment="Stretch" IsHitTestVisible="false" Opacity="0" />

                        <ContentPresenter
                        Content="{TemplateBinding Content}"
                        ContentTemplate="{TemplateBinding ContentTemplate}"
                        HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                        VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                        Margin="{TemplateBinding Padding}" />

                        <Rectangle x:Name="InvalidVisualElement" IsHitTestVisible="False" StrokeThickness="1" Stroke="#FFDC000C" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Opacity="0"/>

                        <Rectangle x:Name="RightGridLine" Grid.Column="1" VerticalAlignment="Stretch" Width="1" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    
    <!--DATAGRID COMPILED STYLE-->
    <Style x:Key="OIDataGrids" TargetType="sdk:DataGrid" BasedOn="{StaticResource OIDataGridStyle}">
        <Setter Property="RowStyle"
                Value="{StaticResource OIDataGridRowStyle}" />
        <Setter Property="CellStyle"
                Value="{StaticResource OIDataGridCellStyle}" />
        <Setter Property="AutoGenerateColumns"
                Value="False" />
        <Setter Property="BorderBrush"
                Value="Transparent" />
        <Setter Property="AreRowDetailsFrozen"
                Value="True" />
        <Setter Property="SelectionMode"
                Value="Single" />
        <Setter Property="CanUserSortColumns"
                Value="True" />
        <Setter Property="HeadersVisibility"
                Value="Column" />
        <Setter Property="GridLinesVisibility"
                Value="None" />
        <Setter Property="RowBackground"
                Value="Transparent" />
        <Setter Property="AlternatingRowBackground"
                Value="Transparent" />
        <Setter Property="VerticalScrollBarVisibility"
                Value="Auto" />
        <Setter Property="IsReadOnly"
                Value="True" />
        <Setter Property="CanUserResizeColumns"
                Value="True" />
        <Setter Property="FontFamily"
                Value="Segoe UI" />
        <Setter Property="FontSize"
                Value="12" />
    </Style>



</ResourceDictionary>
